num = 10


def fuc_1():
    # print(num) 运行失败
    num = 20
    print(num)


def fuc_2():
    # num = num + 100 修改要加global
    global num
    num = num + 100
    print(num)


# 按间距中的绿色按钮以运行脚本。
if __name__ == '__main__':
    print(num)
    fuc_1()
    fuc_2()
    print(num)
